<!--%import("filter/insert_group.xml")-->
<!--%import("filter/update_group.xml")-->

<!--#include("header.html")-->
<!--%load_js_plugin("ui")-->
<!--%load_js_plugin("filebox")-->


<!-- 그룹의 삭제와 관련된 form -->
<form id="fo_group_info" action="./" method="get">
<input type="hidden" name="act" value="procMemberAdminUpdateGroup" />
<input type="hidden" name="group_srl" value="" />
<input type="hidden" name="mode" value="" />
</form>

<table cellspacing="0" class="rowTable">
<thead>
    <tr>
        <th scope="col" class="half_wide"><div>{$lang->group_title}</div></th>
        <th scope="col" class="half_wide"><div>{$lang->description}</div></th>
        <th scope="col"><div>{$lang->regdate}</div></th>
        <th scope="col"><div>{$lang->is_default}</div></th>
        <th scope="col" colspan="2"><div>&nbsp;</div></th>
    </tr>
</thead>
<tbody>
    <!--@if(!count($group_list))-->
    <tr>
        <td colspan="7">{$lang->msg_group_is_null}</td>
    </tr>
    <!--@end-->
    <!--@foreach($group_list as $group_srl => $group_info)-->
    <tr class="row{$cycle_idx}">
        <td><!--@if($config->group_image_mark=='Y' && $group_info->image_mark)--><img src="{$group_info->image_mark}" style="vertical-align: middle; margin-right: 3px;" /><!--@endif-->{$group_info->title}</td>
        <td>{nl2br($group_info->description)}&nbsp;</td>
        <td>{zdate($group_info->regdate,"Y-m-d H:i:s")}</td>
        <td><!--@if($group_info->is_default=='Y')-->Y<!--@else-->&nbsp;<!--@end--></td>
        <td><a href="{getUrl('group_srl',$group_info->group_srl)}" title="{$lang->cmd_modify}" class="buttonSet buttonSetting"><span>{$lang->cmd_modify}</span></a></td>
        <td>
            <!--@if($group_info->is_default!='Y' && $group_info->is_admin !='Y')-->
            <a href="#" onclick="doUpdateGroup('{$group_info->group_srl}','delete','{$lang->confirm_delete}');return false;" title="{$lang->cmd_delete}" class="buttonSet buttonDelete"><span>{$lang->cmd_delete}</span></a>
            <!--@else-->
            &nbsp;
            <!--@end-->
        </td>
    </tr>
    <!--@end-->
</tbody>
</table>


<!-- 그룹 추가 -->
<form action="./" method="get" onsubmit="return procFilter(this, insert_group)">
<input type="hidden" name="page" value="{$page}" />
<input type="hidden" name="group_srl" value="" />

    <table cellspacing="0" class="rowTable">
    <tr>
        <th scope="row"><div>{$lang->group_title}</div></th>
        <td class="wide"><input type="text" name="title" class="inputTypeText w400" /></td>
    </tr>
    <tr class="row2">
        <th scope="row"><div>{$lang->is_default}</div></th>
        <td><input type="checkbox" name="is_default" value="Y" class="checkbox" /> {$lang->about_member_default}</td>
    </tr>
    <tr>
        <th scope="row"><div>{$lang->description}</div></th>
        <td><textarea name="description" class="inputTypeTextArea w400"></textarea></td>
    </tr>

    <tr class="row2">
        <th scope="row"><div>{$lang->group_image_mark}</div></th>
        <td class="left">
            <div id="filebox_preview_image_mark" style="width:100px;height:100px;display:none"></div>
            <input type="hidden" name="image_mark" value="" />
            <span class="button black"><button type="button" onclick="XE.filebox.open(jQuery('[name=image_mark]').get(0), 'jpg,jpeg,gif,png')">{$lang->cmd_select}</button></span>
            <span id="filebox_cancel_image_mark" class="button red" style="display:none"><button type="button" onclick="XE.filebox.cancel('image_mark')">{$lang->cmd_delete}</button></span>
        </td>
    </tr>

    <tr>
        <th colspan="2" class="button">
            <span class="button black strong"><input type="submit" value="{$lang->cmd_registration}" accesskey="s" /></span>
        </th>
    </tr>
    </table>
</form>